home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Format CD 24
/
Amiga Format AFCD24 (Feb 1998, Issue 108).iso
/
-seriously_amiga-
/
shareware
/
virus
/
virus_checkerii
/
install_virus_checker
< prev
next >
Wrap
Text File
|
1998-01-05
|
14KB
|
481 lines
; $VER: Virus_Checker Install 7.18 (26.9.95)
; Script to install Virus_Checker
; Written by Simon Dick of Amigaholics Club (sidick@essex.ac.uk)
; Updated and enhanced by John Veldthuis
; Updated and enhanced again by Alex van Niel
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;
;;; Get the version and revision number of file/device/library/OS/etc
;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;
; INPUTS: Item ; Name of device/file/library/etc. "" for OS version
;
; OUTPUTS: VerN ; (long) version/revision number
; Ver ; Version number
; Rev ; Revision number
; NOTE: Both Ver and Rev returned as 0 if "WV_Item" does not exist
;
(procedure WhatVersion
(
(if (= VerN "")
(set VerNum (getversion)) ; For OS
(set VerNum (getversion VerN))) ; For other "files"
(set Ver (/ VerNum 65536))
(set Rev (- VerNum (* Ver 65536)))
)
)
;Set env var Virus_Checker_Path to installed place
(procedure setVCEnv
(
(set VCPath (expandpath @default-dest))
(set VCPathS (cat
("setenv Virus_Checker_Path \"%s\"\n" VCPath)
("copy env:Virus_Checker_Path envarc: quiet\n")
)
)
(textfile
(dest "T:VCEnvSet")
(append VCPathS)
)
(execute "T:VCEnvSet")
(delete "T:VCEnvSet")
)
)
(set @app-name "Virus_Checker II")
(complete 0)
;(if (= @language "deutsch")
; (
; ; Add the german strings here for example
; (set where_vc "Please put the german strings in here first!"
; )
; )
;)
(if (= @language "nederlands")
(
(set whatinstall (cat "Wilt u Virus_CheckerII volledig installeren "
"of slechts een deel ervan?"
)
)
(set fullinstall "Volledig Installeren")
(set partialinstall "Delen Installeren")
(set installhelp (cat "Volledig Installeren, installeert ALLE Virus CheckerII files naar "
"de gekozen lade, terwijl wanneer u Delen Installeert slechts "
"de benodigde programma files installeert."
)
)
(set where_vc (cat "Kies de directory om Virus_CheckerII in te plaatsen a.u.b."
)
)
(set copyingdir "Kopieren van Virus_CheckerII lade")
(set copybblib "Kopieren van Bootblock.library")
(set copybbfile "Kopieren van Bootblock.brainfile")
(set copyxfdlib "Kopieren van xfdmaster.library")
(set copybguilib "Kopieren van bgui.library")
(set copyxfddecrs "Kopieren van XFD externe uitpakkers, kies a.u.b. de uitpakkers die u wilt installeren")
(set copyvcbrain "Kopieren van VirusChecker.brain")
(set copyvcprog "Kopieren van Virus_CheckerII")
(set instaloverold "Virus_CheckerII wordt geinstalleerd in de WBStartup over een oude versie heen")
(set vcrunfrom "Waar wilt u Virus_CheckerII uit laten opstarten?")
(set bestplace "De beste plaats is vanuit de User-Startup")
(set cantinstalloverdir "U kunt Virus_CheckerII niet over een bestaande lade heen installeren")
(set removebrain (cat "Ik heb versie %ld.%ld van de VirusChecker.brain "
"file in L: gevonden\n"
"Dit is slechts nodig wanneer u Virus_CheckerII vanuit de "
"WBStartup laat opstarten.\n"
"Zal ik deze verwijderen?"
)
)
(set deletebrain "Verwijderen van L:VirusChecker.brain")
(set installguide "Wilt u het online AmigaGuide help bestand installeren?")
(set copyingguide "Kopieren van Virus_Checker.guide")
(set whichlangs (cat "Welke Virus CheckerII lokale catalogen wilt u "
"installeren?")
)
(set langhelp (cat "Kopieren van deze bestanden stelt Virus_CheckerII in staat om "
"met verschillende Lokalen onder Workbench 2.1 of hoger "
"te draaien. Selecteer de cataloog bestand(en) die u "
"wilt gaan gebruiken.")
)
(set adddat "Ik moet de volgende regel aan uw \s:User-Startup\ bestand toevoegen\n\n%s")
(set copycat "Kopieren van Virus_Checker.catalog")
(set needtoreset "Om VirusCheckerII te actieveren is het nodig de computer te resetten")
(set instlrexx "Wilt u de Virus_CheckerII Arexx script(en) installeren?")
(set copyrexx "Welke Arexx script(en) wilt u kopieren?")
)
)
(if (= @language "english")
(
(set whatinstall (cat "Do you want a full installation of Virus CheckerII "
"or just a partial one?"
)
)
(set fullinstall "Full Install")
(set partialinstall "Partial Install")
(set installhelp (cat "Full install installs ALL Virus CheckerII files to "
"the directory chosen, while partial install just installs the "
"program files where needed"
)
)
(set where_vc (cat "Please select directory to put Virus_CheckerII in"
)
)
(set copyingdir "Copying Virus_CheckerII drawer")
(set copybblib "Copying Bootblock.library")
(set copybbfile "Copying Bootblock.brainfile")
(set copyxfdlib "Copying xfdmaster.library")
(set copybguilib "Copying bgui.library")
(set copyxfddecrs "Copying XFD external decrunchers, please choose which ones to install")
(set copyvcbrain "Copying VirusChecker.brain")
(set copyvcprog "Copying Virus_CheckerII")
(set instaloverold "Virus_CheckerII being installed in WBStartup over old version")
(set vcrunfrom "Where do you want to run Virus_CheckerII from?")
(set bestplace "The best place is from the User-Startup")
(set cantinstalloverdir "You can't install Virus_CheckerII over an existing directory")
(set removebrain (cat "I have found version %ld.%ld of the VirusChecker.brain "
"file in L:\n"
"This is only needed if you're running Virus_CheckerII "
"from WBStartup.\n"
"Shall I delete it?"
)
)
(set deletebrain "Deleting L:VirusChecker.brain")
(set installguide "Do you want to install the online AmigaGuide help file?")
(set copyingguide "Copying Virus_Checker.guide")
(set whichlangs (cat "Which Virus CheckerII locale catalogs do you want "
"to install?")
)
(set langhelp (cat "Copying these files will allow Virus_CheckerII to be "
"run using different Locales under Workbench 2.1 or "
"higher. Just select the catalog files which you "
"will need to use.")
)
(set adddat "I need to add the following line to your \s:User-Startup\ file\n\n%s")
(set copycat "Copying Virus_Checker.catalog")
(set needtoreset "You will need to reset to cause VirusCheckerII to be run")
(set instlrexx "Do you want to install the Virus CheckerII ARexx scripts?")
(set copyrexx "Which ARexx scripts do you want to copy?")
)
)
(welcome)
(set VerN "")
(WhatVersion) ;Get version
(if (< Ver 37)
(abort (cat #ver_err1 #err_msg))
)
;If installed already then use that one
(if (= (exists "ENV:Virus_Checker_Path" (noreq)) 1)
(set @default-dest (getenv "Virus_Checker_Path"))
)
(set fullinstall (askbool (default 1)
(prompt whatinstall)
(help installhelp)
(choices fullinstall partialinstall)
)
)
(if fullinstall
(
(set @default-dest
(askdir (prompt where_vc)
(help @askdir-help)
(default @default-dest)
)
)
(complete 10)
; Copy Virus_Checker drawer
(copylib (prompt copyingdir)
(help @copylib-help)
(source "Virus_CheckerII")
(dest @default-dest)
(infos)
(optional oknodelete force)
)
(copylib (prompt copyingdir)
(help @copylib-help)
(source "VirusChecker.brain")
(dest @default-dest)
(optional oknodelete askuser)
)
(copylib (prompt copyingdir)
(help @copylib-help)
(source "Virus_Checker.guide")
(dest @default-dest)
(infos)
(optional nofail askuser)
)
)
; If partial install
(
(debug "")
)
)
(complete 20)
; Install libraries
(copylib (prompt copybblib)
(help @copylib-help)
(source "libs/Bootblock.library")
(dest "LIBS:")
(optional nofail askuser)
)
(complete 30)
(copylib (prompt copybbfile)
(help @copylib-help)
(source "l/Bootblock.brainfile")
(dest "L:")
(optional nofail askuser)
)
(complete 40)
; Unpack library gone
(complete 50)
(copylib (prompt copyxfdlib)
(help @copylib-help)
(source "libs/xfdmaster.library")
(dest "LIBS:")
(optional nofail askuser)
)
(copylib (prompt copybguilib)
(help @copylib-help)
(source "libs/bgui.library")
(dest "LIBS:")
(optional nofail askuser)
)
(complete 60)
(copyfiles (prompt copyxfddecrs)
(help @copyfiles-help)
(source "libs/xfd")
(dest "LIBS:xfd")
(optional nofail askuser)
(confirm)
(all)
)
(complete 70)
; Check if brainfile is in L:
(set brainfile (exists "L:VirusChecker.brain"))
(set wherestart (exists "SYS:WBStartup/Virus_CheckerII"))
(if (= wherestart 0)
(set wherestart (askchoice (prompt vcrunfrom)
(help bestplace)
(default 0)
(choices "User-Startup" "WBStartup" "None")
)
)
(
(if (= wherestart 1)
(message instaloverold)
(abort cantinstalloverdir)
)
)
)
(if (= wherestart 0)
(
(if (= fullinstall 0)
(
(if (exists (tackon @default-dest "Utilities"))
(set @default-dest (tackon @default-dest "Utilities"))
(if (exists "SYS:Utilities")
(set @default-dest (expandpath "SYS:Utilities"))
)
)
(set @default-dest (askdir (prompt "")
(help @askdir-help)
(default @default-dest)
)
)
(copylib (prompt copyvcprog)
(help @copylib-help)
(source "Virus_CheckerII")
(dest @default-dest)
(infos)
(optional oknodelete force)
)
(copylib (prompt copyvcbrain)
(help @copylib-help)
(source "VirusChecker.brain")
(dest @default-dest)
(optional nofail askuser)
)
)
)
)
)
(if (= wherestart 1)
(
(copylib (prompt copyvcbrain)
(help @copylib-help)
(source "VirusChecker.brain")
(dest "L:")
(optional nofail askuser)
)
(copylib (prompt copyvcprog)
(set @default-dest "SYS:WBStartup")
(help @copylib-help)
(source "Virus_CheckerII")
(dest "SYS:WBStartup")
(optional oknodelete force)
(infos)
)
)
(
(if (= brainfile 1)
(
(set VerN "L:VirusChecker.brain")
(WhatVersion) ;Get version
(set rembrain (askbool (prompt (removebrain Ver Rev))
(help @askbool-help)
(default 1)
)
)
(if (= rembrain 1)
(delete ("L:VirusChecker.brain")
(optional force)
)
)
)
)
(if (= wherestartup 0) ; User-Startup
(
(set cmd (tackon @default-dest "Virus_Checker"))
(startup @app-name (prompt (adddat cmd))
(help @startup-help)
(command cmd)
)
)
)
)
)
(complete 80)
(if (askbool (prompt installguide)
(help @askbool-help)
(default 1)
)
(
(copylib (prompt copyingguide)
(help @copylib-help)
(source "Virus_Checker.guide")
(dest "HELP:")
; (dest (cat "HELP:" @language)) Later
(optional nofail force)
)
)
)
(complete 90)
(set localever (/ (getversion "locale.library" (resident)) 65536))
;(if (>= (/ (getversion "locale.library" (resident)) 65536) 38))
(if (>= localever 38)
(
(set locales (askoptions (prompt whichlangs)
(help langhelp)
(choices "nederlands"
"danks"
"svenska"
)
)
)
)
)
(if (IN locales 0)
(
(copylib (prompt copycat)
(help @copylib-help)
(source "catalogs/nederlands/Virus_Checker.catalog")
(dest "LOCALE:Catalogs/nederlands")
(optional nofail askuser)
)
)
)
(if (IN locales 1)
(
(copylib (prompt copycat)
(help @copylib-help)
(source "catalogs/dansk/Virus_Checker.catalog")
(dest "LOCALE:Catalogs/dansk")
(optional nofail askuser)
)
)
)
(if (IN locales 2)
(
(copylib (prompt copycat)
(help @copylib-help)
(source "catalogs/svenska/Virus_Checker.catalog")
(dest "LOCALE:Catalogs/svenska")
(optional nofail askuser)
)
)
)
(set installrexx (askbool (prompt instlrexx)
(help @askbool-help)
(default 1)
)
)
(if installrexx
(copyfiles (prompt copyrexx)
(help @copyfiles-help)
(source "ARexx")
(dest "REXX:")
(all)
(optional nofail askuser)
(confirm)
)
)
(setVCEnv)
(complete 100)
(if (= wherestartup 2)
(exit)
(exit needtoreset)
)